# _*_coding:utf-8_*_
'''
Created on Mar 7, 2014
1. Add DIO control constant, from DAQmx
2. Add CVU control cconstant
@author: JZHAI
'''
# for dio control, from DAQmx
DAQmx_Val_ChanPerLine = 0
DAQmx_Val_ChanForAllLines = 1

DAQmx_Val_Rising = 10280
DAQmx_Val_Falling = 10171

DAQmx_Val_CountUp = 10128
DAQmx_Val_CountDown = 10124
DAQmx_Val_ExtControlled = 10326

DAQmx_Val_GroupByChannel = 0
DAQmx_Val_GroupByScanNumber = 1

DAQmx_Val_Task_Start = 0
DAQmx_Val_Task_Stop = 1
DAQmx_Val_Task_Verify = 2
DAQmx_Val_Task_Commit = 3
DAQmx_Val_Task_Reserve = 4
DAQmx_Val_Task_Unreserve = 5
DAQmx_Val_Task_Abort = 6
# for matrix control, from NI_Swtich
NISWITCH_TOPOLOGY_CONFIGURED_TOPOLOGY = "Configured Topology"
NISWITCH_TOPOLOGY_2534_1_WIRE_8X32_MATRIX = "2534/1-Wire 8x32 Matrix"
NISWITCH_TOPOLOGY_2534_1_WIRE_4X128_MATRIX = "2534/1-Wire 4x128 Matrix"
NISWITCH_VAL_CLOSE_RELAY = 21
NISWITCH_VAL_OPEN_RELAY = 20
# for CVU
CMTR_SPEED_FAST = 0
CMTR_SPEED_NORMAL = 1
CMTR_SPEED_QUIET = 2

CMTR_OUTPUT_OFF = 0  # just turn off CMTR
CMTR_OUTPUT_0V = 1  # set DC bias and AC drive to 0V, output still keep on, to avoid frequently switch the front panel indicator.

# Measurement models
MMODEL = ["ZTR", "RX", "CPG", "CSRS", "CPD", "CSD", "CPQ", "CPRP", "CSQ", "LPD", "LPQ",
          "LPG", "LPRP", "LSD", "LSQ", "LSRS", "ZTD", "GB", "YTD", "YTR", "VDID"]
